﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Ordinaire;

namespace Ordinaire
{
    /// <summary>
    /// Used by any data class that converts a given data to an entity.
    /// </summary>
    /// <typeparam name="TId">type of id</typeparam>
    /// <typeparam name="TWho">type of creator</typeparam>
    public interface IParseEntity
    {
        /// <summary>
        /// Converts its data to a specified entity.
        /// </summary>
        /// <typeparam name="TEntity">entity type</typeparam>
        /// <returns>a new instance of the specified type</returns>
        TEntity ToEntity<TEntity>();
    }
}
